package cn.tedu.tmall.front.mall.service.impl;

import cn.tedu.tmall.front.mall.dao.cache.ICategoryCacheRepository;
import cn.tedu.tmall.front.mall.pojo.vo.CategoryListItemVO;
import cn.tedu.tmall.front.mall.service.ICategoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CategoryServiceImpl implements ICategoryService {

    @Autowired
    private ICategoryCacheRepository categoryCacheRepository;

    @Override
    public List<CategoryListItemVO> listByParent(Long parentId) {
        return categoryCacheRepository.listByParent(parentId);
    }
}
